home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Celestin Apprentice 7
/
Apprentice-Release7.iso
/
Environments
/
Small Eiffel 0.4.8
/
lib_std
/
std_input.e
< prev
next >
Wrap
Text File
|
1997-04-13
|
1KB
|
54 lines
-- Part of SmallEiffel -- Read DISCLAIMER file -- Copyright (C)
-- Dominique COLNET and Suzanne COLLIN -- colnet@loria.fr
--
class STD_INPUT
--
-- To use the standard input file. As for UNIX, the default standard
-- input is the keyboard.
--
-- Notes : - the predefined `std_input' should be use to have only
-- one instance of the class STD_INPUT.
-- - to do reading or writing at the same time on the screen,
-- see STD_INPUT_OUTPUT,
-- - to handle cursor of the screen, see CURSES.
--
inherit
STD_FILE_READ
redefine make, disconnect, read_character
end;
creation {ANY}
make, connect_to
feature {ANY}
make is
do
input_stream := stdin;
end;
disconnect is
local
err: INTEGER;
do
err := fclose(input_stream);
path := Void;
input_stream := stdin;
end;
read_character is
do
std_output.flush;
last_character_memory := fgetc(input_stream);
end;
feature {RUN_FEATURE}
stdin: POINTER is
external "CSE"
end;
end -- STD_INPUT